/*
  Copyright 2012 Google Inc. All Rights Reserved.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/

/* Bootstrap overrides and additions. */

html {
  height: 100%;
}

body {
  height: 100%;
  margin: 0 auto;
  padding: 0;
  width: 100%;
}

h3 {
  color: #222;
  line-height: 1.1;
}

/*
  Override the Bootstrap default (which had the horizontal padding set to 20px 
  on both sides, leading to alignment issues when nesting container-fluid
  elements in the exploration editor).
*/
.container-fluid {
  padding-right: 0;
  padding-left: 0;
}

.oppia-editor h3 {
  font-size: 18px;
  margin: 0;
}

.oppia-editor h4 {
  font-size: 14px;
  margin: 0;
}

.oppia-editor form {
  margin: 0;
}

.oppia-rule-ctrl {
  padding: 2px 3px;
}

p {
  color: #444;
  line-height: 1.5;
  /* The following should be the same as the line-height (1.5). */
  margin: 1.5em 0;
  text-align: left;
  word-spacing: 0;
}

.navbar-static-top .container,
.navbar-fixed-top .container,
.navbar-fixed-bottom .container {
  margin: 0 auto;
  width: 98%;
}

#wrapper {
  min-height: 100%;
  position: relative;
}

/*
  The following rule ensures that, as the viewport gets
  smaller, any media will scale down according to its
  container's width.
*/
img, video, canvas {
  max-width: 100%
}

textarea {
  width: 90%;
}

/*
  This is needed for proper display of tabs. See

  https://github.com/angular-ui/bootstrap/commit/8620aedba99b05822311
*/
.nav, .pagination, .carousel a {
  cursor: pointer;
}

.oppia-editor-header {
  font-size: 110%;
  font-variant: small-caps;
}

.oppia-no-scroll::-webkit-scrollbar {
  display: none;
}

.oppia-save-state-button {
  font-size: 110%;
  font-variant: small-caps;
  font-weight: bold;
  margin: 0 5px 0 5px;
}

.oppia-code {
  font-family: Consolas, Monaco, Lucida Console, Liberation Mono, monospace;
}

.oppia-gallery {
  background-color: #f6f6f6;
  border: 1px solid #bbb;
  border-radius: 3px;
}

.oppia-gallery-menu {
  border-right: 1px solid #bbb;
  float: left;
  min-height: 300px;
  padding: 10px 15px 0 15px;
  width: 150px;
}
.oppia-gallery-menu-title {
  font-size: 120%;
  padding: 12px 0;
}

.oppia-gallery-tiles-container {
  background-color: white;
  border-radius: 3px;
  min-height: 300px;
  padding-top: 10px;
}

.oppia-gallery-tile {
  background-color: #f6f6f6;
  border: 1px solid #CCC;
  border-radius: 3px;
  box-shadow: 0 1px 2px rgba(100,100,100,0.5);
  display: block;
  float: left;
  margin: 7px;
  min-width: 200px;
  padding-bottom: 2px;
  width: 30%;
}

.oppia-gallery-tile-top, .oppia-gallery-tile-bottom {
  padding: 2px 10px;
}
.oppia-gallery-tile-top:hover {
  background-color: #ddd;
}
.oppia-gallery-tile-bottom {
  white-space: nowrap;
}

.oppia-gallery-tile-anchor:hover {
  text-decoration: none;
}

.oppia-gallery-tile-description {
  margin: 10px 0;
}

.oppia-gallery-tile-title {
  color: #888;
  font-size: 120%;
  font-weight: bold;
}
.oppia-gallery-tile-title:hover {
  text-decoration: none;
}
.oppia-gallery-tile-top:hover .oppia-gallery-tile-title {
  color: black;
}

.oppia-gallery-tile-play {
  float: right;
  opacity: 0;
  -webkit-transform: scale(1.5, 1.5);
  -moz-transform: scale(1.5, 1.5);
  transform: scale(1.5, 1.5);
}
.oppia-gallery-tile-top:hover .oppia-gallery-tile-play {
  opacity: 0.5;
}

.oppia-page-title {
  color: #222;
  font-size: 30px;
  margin: 0 0 20px 0;
}

.oppia-content {
  margin: 0 auto;
  max-width: 700px;
  -webkit-overflow-scrolling: touch;
  width: 80%;
}

.oppia-iframe-container {
  -webkit-overflow-scrolling: touch;
}

.oppia-alert-blocks {
  position: fixed;
  width: 80%;
  z-index: 3000;
}

.oppia-reader-response-container {
  margin: 20px 0;
}
.oppia-reader-response-container:before {
  content: "\2767";
}
.oppia-reader-response {
  border-radius: 6px;
  font-style: italic;
  margin: 0 20px;
}

.oppia-response {
  background: #f3f3f3;
  background: rgba(0,0,0,0.04);
  border-radius: 6px;
  padding: 10px 20px;
}

.oppia-btn {
  background-image: -webkit-linear-gradient(top, rgba(255, 204, 139, 0.5), rgba(230, 167, 93, 0.5));
  background-image: -moz-linear-gradient(top, rgba(255, 204, 139, 0.5), rgba(230, 167, 93, 0.5));
  background-image: linear-gradient(top, rgba(255, 204, 139, 0.5), rgba(230, 167, 93, 0.5));
  color: #444;
  border-radius: 3px;
  font: bold 14px/20px Arial, sans-serif;
  padding: 4px 10px;
  text-shadow: 0 -1px 0 rgba(0,0,0,0.15);
  text-transform: uppercase;
}

.oppia-btn:hover {
  background: rgb(255, 177, 84);
}

.oppia-small-font {
  font-size: 1.0em;
}

.oppia-editor-prerequisites-form {
  background: #eee;
  border-radius: 5px;
  padding: 5px;
}

.oppia-license {
  border: 1px solid black;
  padding: 0 30px 0 30px;
  margin-bottom: 10px;
}

/* Adds to existing Bootstrap CSS rule. */
.alert-block {
  border: 1px solid black;
  -moz-border-radius: 5px;
  -webkit-border-radius: px;
  border-radius: 5px;
  -moz-box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  -webkit-box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  font-size: 1.2em;
  margin: 0 25% 0 25%;
  opacity: 1;
  width: 80%;
  z-index: 3000;
}

.oppia-form input.ng-invalid.ng-dirty {
  border: 2px solid #FA787E;
}

.oppia-form input.ng-valid.ng-dirty {
  border: 2px solid #78FA89;
}

.oppia-gallery-frame {
  border-radius: 20px;
  margin: 10px;
  padding: 10px;
  width: 100%;
}

.oppia-lightly-grayed {
  color: #888;
}

.oppia-grayed {
  color: gray;
  opacity: 0.5;
}

.oppia-rte-inactive {
  border: 1px solid #ddd;
  background-color: #eee;
  padding: 2px;
}

.oppia-help {
  height: 16px;
  width: 16px;
}

.oppia-main-body {
  height: 100%;
  margin: 0 auto -4em;
  min-height: 100%;
  padding-bottom: 3em;
}

.oppia-footer {
  border-top: 1px solid #DDD;
  bottom: 0;
  height: 3em;
  max-height: 3em;
  margin: auto;
  position: absolute;
  width: 100%;
}

.oppia-exploration-header {
  margin: 10px auto;
  padding: 6px 0;
  text-align: center;
  width: 80%;
}
.oppia-exploration-header a {
  font-size: 200%;
  text-decoration: none;
}

.oppia-wide-panel {
  border: 1px solid black;
  border-radius: 20px;
  width: 100%;
}

.oppia-wide-panel-content {
  font-size: large;
  margin: 5px auto;
  min-height: 400px;
  padding: 20px;
}

.oppia-wide-panel-title {
  color: #062770;
  font-family: verdana, arial, helvetica, sans-serif;
  font-size: 24pt;
  font-weight: bold;
  margin-bottom: 30px;
}

.oppia-btn-container {
  padding: 10px;
}

.oppia-loading {
  background: url(/images/loading.gif) no-repeat center;
  display: none;
  float: left;
  height: 15px;
  margin: 3px;
  width: 15px;
}

.oppia-warning {
  background: #F9EDBE;
  width: 80%;
}

.oppia-conversation-log {
  opacity: 0.7;
}

.oppia-cursor-pointer {
  cursor: pointer;
}

.oppia-editable-name {
  color: #8f8661;
  font-weight: bold;
}
.oppia-editable-name:hover {
  background: #efefef;
  cursor: pointer;
}
.oppia-editable-name:hover::after {
  content: ' ✎';
}

.oppia-placeholder {
  color: gray;
}

.oppia-state-content {
  border-left: 1px dashed #bbb;
  border-right: 1px dashed #bbb;
  border-top: 1px dashed #bbb;
  min-height: 20px;
  padding: 5px;
}

.oppia-widget-preview {
  border-bottom: 1px dashed #bbb;
  border-left: 1px dashed #bbb;
  border-right: 1px dashed #bbb;
  margin: 0 0 2px 0;
}

/* Styles for the state graph vizualization. */

.oppia-graph-viz path.link {
  fill: none;
  stroke: #666;
  stroke-width: 1.5px;
}

.oppia-graph-viz ellipse {
  fill: #ccc;
  stroke: #333;
  stroke-width: 1.5px;
}

.oppia-graph-viz text {
  font: 15px sans-serif;
  pointer-events: none;
}

.oppia-graph-viz text.shadow {
  stroke: #fff;
  stroke-width: 3px;
  stroke-opacity: .8;
}

.oppia-graph-viz .node rect {
  cursor: pointer;
  fill: #fff;
  fill-opacity: .5;
  stroke-width: 0px;
}

.oppia-graph-viz .clickable {
  cursor: pointer;
}

/* Styles for interactive widgets. */

.oppia-rule {
  height: 30px;
}

/* Styles for the statistics page. */

.oppia-stats-table {
  border: 1px solid black;
  padding: 10px;
}

@media screen and (max-width: 460px) {
  .pull-right {
    float: none;
    width: auto;
  }
}

.oppia-feedback-button {
    transition-property: all;
    transition-duration: 0.2s;
    align-content: center;
    background: green;
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
    bottom: 10px;
    box-shadow: -5px 5px 3px #CCCCCC;
    color: white;
    cursor: pointer;
    font-size: 15px;
    font-weight: bold;
    height: 90px;
    left: 0;
    opacity: 0.75;
    position: fixed;
    top: 50%;
    width: 100px;

    -moz-transform-origin: 25px 75px;
    -ms-transform-origin: 25px 75px;
    -o-transform-origin: 25px 75px;
    -webkit-transform-origin: 25px 75px;
    transform-origin: 25px 75px;

    -moz-transform: rotate(-90deg);
    -ms-transform: rotate(-90deg);
    -o-transform: rotate(-90deg);
    -webkit-transform: rotate(-90deg);
    transform: rotate(-90deg);
}
.oppia-feedback-button:hover {
    opacity: 1;
    -moz-transform-origin: 35px 65px;
    -ms-transform-origin: 35px 65px;
    -o-transform-origin: 35px 65px;
    -webkit-transform-origin: 35px 65px;
    transform-origin: 35px 65px;
}

.oppia-rule-bubble {
    background: steelblue;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    padding: 3px;
    color: #ffffff;
    text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}

.oppia-rule-bubble-warning {
    background: #F9EDBE;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    padding: 3px;
    color: #000;
    text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}

.oppia-feedback-bubble {
    background: #E0E0E0;
    border-bottom-left-radius: 8px;
    padding: 5px;
    width: 80%;
}

.oppia-dest-bubble {
    background: #EEEEEE;
    border-bottom-right-radius: 8px;
    padding: 5px;
    width: 20%;
}
